package com.situ.day23.singleton;

import org.junit.Test;

public class Demo {

    @Test
    public void test1() {
        //Singleton1 singleton1 = new Singleton1();
        //Singleton1 singleton2 = new Singleton1();

        Singleton1.test();
        Singleton1 instance1 = Singleton1.getInstance();
        Singleton1 instance2 = Singleton1.getInstance();
        System.out.println(instance1 == instance2);//true
    }

    @Test
    public void test2() {
        System.out.println(Season.SPRING);
    }
}
